<template>
  <div>
   <article-item v-for="obj in articleList" :key="obj.art_id" :articleObj="obj"></article-item>
  </div>
</template>

<script>
import ArticleItem from './components/ArticleItem'
import { getArticleListAPI } from '@/api'
export default {
  props: {
    channel_id: Number
  },
  data () {
    return {
      articleList: []
    }
  },
  components: {
    ArticleItem
  },
  async created () {
    const res = await getArticleListAPI(this.channel_id)
    // console.log(res)
    this.articleList = res.data.data.results
  }
}
</script>

<style>

</style>
